\hypertarget{hoffman_8cpp}{
\subsection{Examples/03Laplace/hoffman.cpp File Reference}
\label{hoffman_8cpp}\index{Examples/03Laplace/hoffman.cpp@{Examples/03Laplace/hoffman.cpp}}
}


Another example of Laplace equation in 2D.  




\subsubsection{Detailed Description}
\begin{DoxyAuthor}{Author}
Luis M. de la Cruz Salas \mbox{[} Fri Mar 21 12:26:33 GMT 2010 \mbox{]}
\end{DoxyAuthor}
This code solves the Laplace equation in two dimensions: $ \nabla^2 T = 0$ in the rectangle $ [0,1] \times [0,2] $. The boundary conditions are as shown in the next figure:  
\begin{DoxyImage}
\includegraphics[width=10cm]{LaplaceSquare}
\caption{Unit square in 2D}
\end{DoxyImage}
 \begin{DoxyParagraph}{}
The exact solution of this problem is: \[ T(x,y) = 10\sin(\pi x) \frac{e^{\pi x}-e^{-\pi y}}{e^{\pi}-e^{-\pi}} \] 
\end{DoxyParagraph}
\begin{DoxyParagraph}{}
To compile and run this example type the next commands: 
\end{DoxyParagraph}
\begin{DoxyParagraph}{}
\begin{DoxyVerb}
   % make
   % ./hoffman \end{DoxyVerb}

\end{DoxyParagraph}
The results of this example are stored in {\ttfamily DataHoffman} and are plotted using OpenDX with the script {\ttfamily visdat.net}, look at the next figures.    

Definition in file \hyperlink{hoffman_8cpp_source}{hoffman.cpp}.

